package com.android.pandoid;

import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;

/**
 * Date: 2020/8/19 11:12
 * Author: Tatum
 * Description: TODO
 */
class PersonInvocationHandler implements InvocationHandler {

    private Object target;

    public PersonInvocationHandler(Object target) {
        this.target = target;
    }

    @Override
    public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
        System.out.println("method  name="+method.getName());
        return method.invoke(target,args);
    }
}
